//
//  GoalCounts.m
//  KConnect
//
//  Created on 18/03/09.
//  Copyright 2009 Xtreme Labs Inc. All rights reserved.
//

#import "KCGoalCounts.h"


#define kGoalCounts   @"gci"

#define kUID          @"s"
#define kGoalCountID  @"gc"

@implementation KCGoalCounts

- (id)initWithUIDs:(NSArray*)uid
{
  NSDictionary *required = [NSDictionary dictionaryWithObjectsAndKeys: [self buildCommaString:uid], kUID, nil];
  
  if(self = [super initWithParameters:required])
  {
    
  }
  return self;
}

- (void)setGoalCount:(NSInteger)count value:(NSInteger)value
{
  NSString * countString = [NSString stringWithFormat:@"gc%d", count];
  NSString * valueString = [NSString stringWithFormat:@"%d", value];
  
  //We disable verification
  [self addOptionalParameter:countString value:valueString verify:NO];
}

- (NSString*)messageType
{
  return kGoalCounts;
}

- (NSArray*)requiredParameters
{
  return [NSArray arrayWithObjects:kUID, nil];
}


//This is exceptional because we can have gcN params where N is variable
- (NSArray*)optionalParameters
{
	return [NSArray array];
}




@end
